﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using CXMLStudioIDE.WinFormsUI.CXMLStudioControls;
using System.Windows.Forms;
using CXMLStudioIDE.Common;
using CXMLStudioIDE.Common.Entities;
using System.ComponentModel;
using System.Collections;
using CXMLStudioIDE.Forms;
using CXMLStudioIDE.Presenters;

namespace CXMLStudioIDE.Views
{
    public interface IMainView
    {
        #region Properties
        DisplayContext Context { get; set; }
        TreeNode ProjectExplorerSelectedNode { get; }
        object PropertyGridSelectedObject { get; set; }
        string TreeViewWindowTitle { set;  }
        string TreeViewToolTipText { get; set; }
        CXMLTreeNode CurrentRootNode { get; }
        GoldEntryForm CallingGoldForm { get; set; }
        CXMLTreeNode CallingCXMLTreeNode { get; set; }
        AddInstanceForm.AddInstanceMode MyAddInstanceMode { get; set; } 
        #endregion

        #region Methods
        void ShowDataDictionary();
        void ShowPropertyWindow();
        void ShowTreeView();
        BusinessEntity GetCurrentTreeViewBusinessEntity();
        void UpdateDataDictionary(BusinessEntity be);
        void LoadTreeView(BusinessEntity be, DisplayContext context,Type EntityType, object instance);
        void NewFormDesignerForm();
        void NewAddInstanceForm(CXMLTreeNode node);
        void NewGoldEntryForm(CXMLTreeNode node, GoldEntryForm CallingGoldForm, CXMLTreeNode CallingCXMLNode, CXMLStudioIDE.Forms.AddInstanceForm.AddInstanceMode addInstanceArgs);
        void SetFocusOnTreeView(CXMLTreeNode node);
        void StopTreeViewProgressBar();
        void AddInstanceTreeToNode(BusinessEntity be, CXMLTreeNode RootNode);
        void SelectSolutionExplorerNodeById(int treeViewId);
        void SetTreeViewSelectedNode(CXMLTreeNode node);
        void ResetSolutionExplorerNodesColor();
        #endregion

        #region Events
        event TreeNodeMouseClickEventHandler OnCXMLTreeNodeClick;
        event TreeViewEventHandler OnCXMLTreeNodeSelectionChange;
        event TreeNodeMouseClickEventHandler OnProjectExplorerNodeDoubleClick;
        event KeyPressEventHandler OnProjectExplorerKeyPress;
        event EventHandler OnActiveDocumentChanged;
        event PropertyValueChangedEventHandler OnPropertyValueChanged;
        event FormDesigner.OnFormCompletedEventHandler OnFormCompleted;
        event FormDesigner.OnEntityDroppedEventHandler OnEntityDroppedInFormDesigner;
        event GoldEntryForm.OnFormCompletedEventHandler OnGoldFormCompleted;
        event GoldEntryForm.OnGoldFormLoadingEventHandler OnGoldFormLoading;
        event GoldEntryForm.OnInstanceAddedEventHandler OnInstanceAdded;
        event CXMLTreeView.OnTreeViewUpdatedEventHandler OnTreeViewUpdated;
        event CXMLTreeView.OnTreeNodeHoverEventHandler OnTreeNodeHover;
        event CXMLTreeView.OnTreeViewMouseMoveEventHandler OnTreeViewMouseMove;
        event AddInstanceForm.OnAddInstanceEventHandler OnAddInstance;
        #endregion
    }
}
